# -*- coding: UTF-8 -*-

__author__ = 'anan'

import redis


class Cache:
    def __init__(self):
        self.cache = redis.Redis('localhost')

    def set_status(self, user, value):
        self.cache.set(user+'_status', value)

    def get_status(self, user):
        return self.cache.get(user+'_status')

    def set_tag(self, user, value):
        self.cache.set(user+'_tag', value)

    def get_tag(self, user):
        return self.cache.get(user+'_tag')